package com.study.talk.netty.message.response;

import com.study.talk.netty.message.MessageType;
import com.study.talk.netty.message.TalkMessage;


/**
 *  注册消息的响应
 */



public class RegisterResponse extends TalkMessage {

    private Boolean success;

    private String reason;

    private Integer userId;

    private String username;

    private String token;

    @Override
    public byte getType() {
        return MessageType.REGISTER_RESPONSE;
    }


    public RegisterResponse(Boolean success, String reason, Integer userId, String username, String token) {
        this.success = success;
        this.reason = reason;
        this.userId = userId;
        this.username = username;
        this.token = token;
    }

    public RegisterResponse() {
    }

    public Boolean getSuccess() {
        return success;
    }

    public void setSuccess(Boolean success) {
        this.success = success;
    }

    public String getReason() {
        return reason;
    }

    public void setReason(String reason) {
        this.reason = reason;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }
}
